Contrast stretching (also known as histogram stretching) is an image processing algorithm used for normalization of images. During the process of normalization, the range of intensity values of the pixels in the images is changed. The normalization process scales the brightness values of the image, so that the darkest point in the image becomes black and the brightest point in the image becomes as bright as possible, wherein the hue of the image may not be changed. Normalization may be used to improve the contrast of images with poor contrast.
Currently, generic image processing programs and GIS application may be used for normalization of images. These algorithms may be used for greyscale images. Algorithms used by these programs and/or applications for normalization of multi-spectral images may be inefficient in terms of usage of resources of the device running the programs and/or applications, the algorithms may be computationally intensive. Also, some of the algorithms may result in color change of the pixels of the image, resulting in the image acquiring an artificial appearance.
In a first method, where RGB (Red, Green and Blue) in an image is translated into IHS (Intensity, Hue, and Saturation). Then, the contrast stretch of I channel is done to I′. Then, the I′HS is translated to R′G′B′. However, the translations from RGB to IHS to I′HS to RGB are very costly and the overall algorithm is slow.
In a second algorithm, the histogram stretch is applied on the R, G and B channels of the images separately. However, this may result in a change in the colour of the image and provides an artificial appearance to the image.
In another algorithm, the luminance channel from RGB is computed usingLuminance=0.3R+0.59G+0.11B. The color map is computed using the luminance channel. The colour map is then applied on the R, G and B channels of the image. However, this may result in a change in the colour of the image and provides an artificial appearance to the image.
In another algorithm, the RGB in the image is translated to YUV. Then image enhancements are applied to Y to get Y′. Y′UV is translated to R′G′B′. However, the translations from RGB to YUV to Y′UV to R′G′B′ are very costly and the overall algorithm is slow.